package com.hmy.material.service.impl;

import com.hmy.material.domain.HmyMateriaFeedType;
import com.hmy.material.mapper.TypeMapper;
import com.hmy.material.service.TypeService;
import org.apache.ibatis.annotations.Param;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author zxh
 * @version 1.0
 * @description: 饲料类型业务实现类
 * @date 2024/2/28 17:18
 */
@Service
public class TypeServiceImpl implements TypeService {

    @Resource
    private TypeMapper typeMapper;

    @Override
    public List<HmyMateriaFeedType> selectTypeList(String materiaFeedType, String creationDateStart, String creationDateEnd) {
        return typeMapper.selectTypeList(materiaFeedType, creationDateStart, creationDateEnd);
    }

    @Override
    public HmyMateriaFeedType selectTypeById(Long materiaFeedTypeId) {
        return typeMapper.selectTypeById(materiaFeedTypeId);
    }

    @Override
    public int addType(HmyMateriaFeedType type) {
        return typeMapper.addType(type);
    }

    @Override
    public int updateType(HmyMateriaFeedType type) {
        return typeMapper.updateType(type);
    }

    @Override
    public int delTypeById(Long materiaFeedTypeId) {
        return typeMapper.delTypeById(materiaFeedTypeId);
    }

    @Override
    public int delTypeByIds(Long[] materiaFeedTypeIdS) {
        return typeMapper.delTypeByIds(materiaFeedTypeIdS);
    }

    @Override
    public List<HmyMateriaFeedType> getTypes() {
        return typeMapper.getTypes();
    }
}
